@import "./variables.scss";
@import "./mixin.scss";
@import "./transition.scss";
@import "./element-ui.scss";
@import "./sidebar.scss";

body {
  height: 100%;
  -moz-osx-font-smoothing: grayscale;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-family: Helvetica Neue, Helvetica, PingFang SC, Hiragino Sans GB, Microsoft YaHei, Arial, sans-serif;
}

label {
  font-weight: 700;
}

html {
  height: 100%;
  box-sizing: border-box;
  background-color: #fafafa;
}

#app {
  height: 100%;
}

*,
*:before,
*:after {
  box-sizing: inherit;
}

a:focus,
a:active {
  outline: none;
}

a,
a:focus,
a:hover {
  cursor: pointer;
  color: inherit;
  text-decoration: none;
}

div:focus {
  outline: none;
}

.clearfix {
  &:after {
    visibility: hidden;
    display: block;
    font-size: 0;
    content: " ";
    clear: both;
    height: 0;
  }
}

// main-container global css
.app-container {
  padding: 20px;
}

// 文本对齐 样式类
$text--list: left,
center,
right;

@each $text in $text--list {
  .text-#{$text} {
    text-align: $text;

    .el-button:last-child {
      margin-right: 0 !important;
    }
  }
}

// 文本对齐 样式类
$colorList: ((colorName: 'success', colorNum: #67c23a),
(colorName: 'danger', colorNum: #f56c6c),
(colorName: 'warning', colorNum: #e6a23c),
(colorName: 'info', colorNum: #909399),
(colorName: 'primary', colorNum: #409eff));

@for $i from 1 through length($colorList) {
  $item: nth($colorList, $i);
  $colorName: map-get($map: $item, $key: colorName);
  $colorNum: map-get($map: $item, $key: colorNum);

  .text-#{$colorName} {
    color: $colorNum;
    font-weight: bold;
  }
}

@for $i from 1 to 200 {
  .mt-#{$i} {
    margin-top: #{$i};
  }
}

.main-bg {
  margin: 24px;
  background-color: #fff;
  box-sizing: border-box;
  position: relative;
  border-radius: 4px;
}

.data-table {
  margin-top: 16px;
}

.file-list {
  display: flex;
  margin: 10px;
  align-items: center;
  flex-wrap: wrap;

  .file {
    cursor: pointer;

    .btn {
      margin-right: 12px;
      font-weight: bold;
    }

    &:hover {
      color: #409eff;
    }
  }
}

.drawer-main {
  padding: 0 20px;
  height: calc(100vh - 145px);
  overflow-y: auto;
}

.drawer-footer {
  height: 64px;
  box-shadow: 0 -2px 12px 0 rgba(0, 0, 0, .06);
}

.footer-btn {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  flex-direction: row-reverse;

  .el-button {
    margin-right: 12px;
  }
}

.footer {
  position: fixed;
  height: 64px;
  box-shadow: 0 -2px 12px 0 rgba(0, 0, 0, .06);
  bottom: 0;
  background: #fff;
  margin-left: -24px;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 999;
  padding-right: $sideBarWidth;
  width: calc(100%);
}
